package cn.hbu.zlfw.admin.service.impl;

import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import cn.hbu.zlfw.admin.dao.ScienceExpertDao;
import cn.hbu.zlfw.admin.entity.ScienceExpert;
import cn.hbu.zlfw.admin.service.ScienceExpertService;
import cn.hbu.zlfw.common.base.service.impl.BaseServiceImpl;
import cn.hbu.zlfw.common.util.PageModel;

/**
 * 
 * @ClassName: ScienceExpertServiceImpl 
 * @Description: 科技服务人员service接口实现
 * @author 王鹏伟<1223443289@qq.com>
 * @date 2017年11月27日 下午9:03:41 
 * @vsersion:v1.0
 */
@Service("scienceExpertService")
@Transactional
public class ScienceExpertServiceImpl extends BaseServiceImpl<ScienceExpert, String> implements ScienceExpertService{
	
	@Autowired
	private ScienceExpertDao scienceExpertDao;
	/*
	 * (non-Javadoc)
	 * @see cn.hbu.zlfw.admin.service.ScienceExpertService#getScienceExpertByParam(java.util.Map)
	 */
	@Override
	public ScienceExpert getScienceExpertByParam(Map<String, Object> params) {
		return this.scienceExpertDao.getScienceExpertByParam(params);
	}
	/**
	 * 条件分页查询邀请列表:排除接单科技服务人员和已邀请协助人员
	 */
	@Override
	public PageModel<ScienceExpert> listInviteScienceExpertByParams(PageModel<ScienceExpert> pageModel, String userName,
			List<String> scienceExpertIds) {
		return this.scienceExpertDao.listInviteScienceExpertByParams(pageModel,userName,scienceExpertIds);
	}
	/*
	 * (non-Javadoc)
	 * @see cn.hbu.zlfw.admin.service.ScienceExpertService#listAllScienceByParamsToUnit(cn.hbu.zlfw.common.util.PageModel, java.lang.String, java.lang.Integer)
	 */
	@Override
	public PageModel<ScienceExpert> listAllScienceByParamsToUnit(PageModel<ScienceExpert> pageModel, String userName,
			Integer schoolType) {
		return this.scienceExpertDao.listAllScienceByParamsToUnit(pageModel,userName,schoolType);
	}
	/*
	 * (non-Javadoc)
	 * @see cn.hbu.zlfw.admin.service.ScienceExpertService#listScienceExpertByParamsToUnit(java.lang.String, java.lang.String, java.lang.Integer)
	 */
	@Override
	public PageModel<ScienceExpert> listScienceExpertByParamsToUnit(PageModel<ScienceExpert> pageModel,String userName, String department,
			Integer schoolType) {
		return this.scienceExpertDao.listScienceExpertByParamsToUnit(pageModel,userName,department,schoolType);
	}
	/*
	 * (non-Javadoc)
	 * @see cn.hbu.zlfw.admin.service.ScienceExpertService#getScienceExpertToUpdate(java.lang.String, java.lang.String)
	 */
	@Override
	public ScienceExpert getScienceExpertToUpdate(String phoneNumber, String id) {
		return this.scienceExpertDao.getScienceExpertToUpdate(phoneNumber,id);
	}



}
